package com.program.facesigninsystem.config;

import cn.yueshutong.springbootstartercurrentlimiting.annotation.CurrentLimiter;
import cn.yueshutong.springbootstartercurrentlimiting.handler.CurrentAspectHandler;
import com.program.facesigninsystem.entity.ResponseModel;
import org.aspectj.lang.ProceedingJoinPoint;
import org.springframework.stereotype.Component;

/**
 * @author Mapler
 */
@Component
public class MyCurrentLimitHandler implements CurrentAspectHandler {
    @Override
    public ResponseModel around(ProceedingJoinPoint pjp, CurrentLimiter rateLimiter)  {
        return new ResponseModel(500,"系统繁忙，请稍后重试");
    }
}
